package com.ms.education.statistics;

import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.cloud.client.discovery.EnableDiscoveryClient;
import org.springframework.cloud.openfeign.EnableFeignClients;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.scheduling.annotation.EnableScheduling;

/**
 * <p>Project:education-StatisticsApplication
 * <p>Powered by ms on 2023-01-22 15:29:43
 *
 * @author ms
 * @version 1.0
 * @since 1.8
 */
@SpringBootApplication
@ComponentScan(basePackages = {"com.ms.education"})
@EnableDiscoveryClient
@EnableFeignClients
@EnableScheduling
public class StatisticsApplication {
    public static void main(String[] args) {
        SpringApplication.run(StatisticsApplication.class, args);
    }

//    public void initSchedulerxWorker(@Value("${schedulerx2.endpoint}")String endpoint,
//                                     @Value("${schedulerx2.namespace}")String namespace,
//                                     @Value("${schedulerx2.groupId}")String groupId,
//                                     @Value("${schedulerx2.appKey}")String appKey) throws Exception {
//        SchedulerxWorker schedulerxWorker = new SchedulerxWorker();
//        schedulerxWorker.setEndpoint(endpoint);
//        schedulerxWorker.setNamespace(namespace);
//        schedulerxWorker.setGroupId(groupId);
//        //1.2.1及以上版本需要设置应用key
//        schedulerxWorker.setAppKey(appKey);
//        schedulerxWorker.init();
//    }
}
